<?php
class Page {
	private $__config;
	
	function __construct($config){
		$this->__config = &$config;
	}
	
	function __destruct(){
		
	}
	
	public function toString(){
		$api_mod = (isset($_GET['api_mod']) && $_GET['api_mod'] != '')?$_GET['api_mod']:'';
		if ($api_mod !=''){
			include dirname(__FILE__). '/'.$api_mod.'/index.php';
			$response = new Response($this->__config);
			return $response->toString();
		}
		return '';
	}
}
?>